import { Routes } from '@angular/router';
import { IndexComponent } from './index/index.component';
import { StudyListComponent } from './study/study-list/study-list.component';
import { studyRoutes } from './study/study-list/study.router';
import { SunshineEmpComponent } from "./sunshine-emp/sunshine-emp.component";
import { AngularBaseComponent } from './study/angular-base/angular-base.component';
import { angularBaseRouterRoutes } from './study/angular-base/angular-base-router.routing';
import { LoginComponent } from './login/login.component';
import { SettingComponent } from './setting/setting.component';
import { settingRoutes } from './setting/setting.router';

export const routes: Routes = [
    { path: '', redirectTo: 'login', pathMatch: 'full' },
    { path: 'login', component: LoginComponent, title: '登录' },
    {
        path: 'index', component: IndexComponent, children:
            [
                { path: 'sunshine-emp', component: SunshineEmpComponent },
                { path: 'study', component: StudyListComponent, children: studyRoutes },
                { path: 'angular-base', component: AngularBaseComponent, children: angularBaseRouterRoutes },
                {path:'sys',component:SettingComponent,children:settingRoutes}
            ],

    },

];
